package com.ziyun.job.modules.job.task.seller;

import com.baomidou.mybatisplus.plugins.Page;
import com.ziyun.erp.modules.capital.entity.MerchantOrderAccountEntity;
import com.ziyun.erp.modules.capital.service.MerchantOrderAccountService;
import com.ziyun.erp.modules.order.entity.OrderInfoEntity;
import com.ziyun.erp.modules.order.service.ErpOrderService;
import com.ziyun.erp.modules.order.service.OrderInfoService;
import io.renren.common.utils.StringUtil;
import lombok.extern.slf4j.Slf4j;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * @author guizhao
 * @Description: 自动生成商户金额订单
 * @date 2018-10-19 10:49
 */
@Slf4j
@Component("synSellerOrderTask")
public class SynSellerOrderTask {
    private  static  Logger logger = LoggerFactory.getLogger(SynSellerOrderTask.class);

    @Autowired
    private OrderInfoService orderInfoService;
    @Autowired
    private MerchantOrderAccountService merchantOrderAccountService;

    /**
     * 自动生成商户金额订单
     */
    public void synSellerOrder(){
//        // 查询所有已完成,未生产提现金额订单
//        List<MerchantOrderAccountEntity> orderInfoEntityList =  merchantOrderAccountService.selectFinishSellerOrderNotSyn(
//                new Page<MerchantOrderAccountEntity>()
//        );
        merchantOrderAccountService.synSellerOrder();
        log.info("====================自动生成商户金额订单 计划任务完成===================");
    }


}
